<html>
<head><meta charset="utf-8"><title>halp: rustc_llvm build fail · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html">halp: rustc_llvm build fail</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="214884280"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214884280" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214884280">(Oct 28 2020 at 19:10)</a>:</h4>
<p>Hi all, I'm having trouble running the basic compiling instructions. it seems LLVM built and installed ok, but <code>x.py build -i  library/std</code> fails when compiling rust_llvm<br>
In particular, it seems to fail when compiling <code>"llvm-wrapper/RustWrapper.cpp"</code> among the warnings output by cargo I see</p>
<p><code>cargo:warning=/usr/include/c++/9.3/type_traits:1301:12: error: invalid use of incomplete type 'struct LLVMOpaqueMetadata'</code></p>
<p>I'm not sure what steps to take, since it seems to be something with my system libraries, and I was able to do a full build of rustc last week. <br>
Which questions should I be asking myself?</p>



<a name="214884358"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214884358" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214884358">(Oct 28 2020 at 19:11)</a>:</h4>
<p>hmm I think <span class="user-mention" data-user-id="224471">@Lokathor</span> ran into issues like this yesterday</p>



<a name="214884371"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214884371" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214884371">(Oct 28 2020 at 19:11)</a>:</h4>
<p><span class="user-mention" data-user-id="116122">@simulacrum</span>  was there an LLVM bump recently?</p>



<a name="214884396"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214884396" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214884396">(Oct 28 2020 at 19:11)</a>:</h4>
<p><span class="user-mention" data-user-id="209053">@Iñaki Garay</span> if you're only working on the standard library you could work around it for now by using <code>build --stage 0 library/std</code></p>



<a name="214885209"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214885209" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214885209">(Oct 28 2020 at 19:19)</a>:</h4>
<p>actually I wanted to try some things out with tracing for the bit about logging I'm adding to the guide. <br>
I'll try to find an earlier commit that works but I get the feeling that's not it.</p>



<a name="214892551"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214892551" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214892551">(Oct 28 2020 at 20:21)</a>:</h4>
<p>you can see the LLVM bumps here: <a href="https://github.com/rust-lang/rust/commits/master/src/llvm-project">https://github.com/rust-lang/rust/commits/master/src/llvm-project</a></p>



<a name="214892700"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214892700" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214892700">(Oct 28 2020 at 20:22)</a>:</h4>
<p>thank you for that link</p>



<a name="214896854"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214896854" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214896854">(Oct 28 2020 at 20:59)</a>:</h4>
<p>well, went back to a commit fro Oct13 and was able to run <code>x.py build</code>succesfully, so I no longer think I'm going crazy. I'll try to narrow it down with that list.</p>



<a name="214897106"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897106" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897106">(Oct 28 2020 at 21:01)</a>:</h4>
<p><span class="user-mention" data-user-id="138448">@cuviper</span> did llvm update the minimum version of cmake needed lately or something?</p>



<a name="214897348"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897348" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897348">(Oct 28 2020 at 21:03)</a>:</h4>
<p>I think 11 is warning about that, and the master branch toward 12 has increased to cmake 3.13.4</p>



<a name="214897717"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897717" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897717">(Oct 28 2020 at 21:06)</a>:</h4>
<p><span class="user-mention" data-user-id="209053">@Iñaki Garay</span> I guess the 11-final update on Oct14 would have the most churn in LLVM itself</p>



<a name="214897752"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897752" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897752">(Oct 28 2020 at 21:07)</a>:</h4>
<p>the other stuff looks minor, but I don't have the context for your error message</p>



<a name="214897753"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897753" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897753">(Oct 28 2020 at 21:07)</a>:</h4>
<p>yeah</p>



<a name="214897868"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214897868" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214897868">(Oct 28 2020 at 21:08)</a>:</h4>
<p>do you want it? my box is compiling  <a href="https://github.com/rust-lang/rust/commit/bd145a30489e0dd529889627eb350c9cb5990f71#diff-7cdb6543de7f569620c298122578d643fe4ee829c4e2aa313b129e8932f07929">https://github.com/rust-lang/rust/commit/bd145a30489e0dd529889627eb350c9cb5990f71#diff-7cdb6543de7f569620c298122578d643fe4ee829c4e2aa313b129e8932f07929</a> but I can re run master and paste more context here if it'll help</p>



<a name="214898005"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898005" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898005">(Oct 28 2020 at 21:09)</a>:</h4>
<p>for my purposes just finding a recent version that builds is fine</p>



<a name="214898115"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898115" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898115">(Oct 28 2020 at 21:10)</a>:</h4>
<p>no rush, next time you hit the error let's capture more of it</p>



<a name="214898137"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898137" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898137">(Oct 28 2020 at 21:10)</a>:</h4>
<p>I have gcc 9.3.0 and cmake 3.18.2</p>



<a name="214898159"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898159" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898159">(Oct 28 2020 at 21:10)</a>:</h4>
<p>I got a longer snippet from <span class="user-mention silent" data-user-id="224471">Lokathor</span> , one sec</p>



<a name="214898187"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898187" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898187">(Oct 28 2020 at 21:11)</a>:</h4>
<p>oh boo it was just a video and I didn't save it</p>



<a name="214898577"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898577" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898577">(Oct 28 2020 at 21:14)</a>:</h4>
<p>it could also be this change to <code>rustc_llvm</code>:<br>
<a href="https://github.com/rust-lang/rust/pull/68965/files#diff-b9d202534dd2844b76444d5ecca2536e97ff29913a69be05d4585c9f98bac797">https://github.com/rust-lang/rust/pull/68965/files#diff-b9d202534dd2844b76444d5ecca2536e97ff29913a69be05d4585c9f98bac797</a></p>



<a name="214898991"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214898991" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214898991">(Oct 28 2020 at 21:18)</a>:</h4>
<p>I suspect <code>cast&lt;MDNode&gt;(DL)</code> should have <code>unwrap(DL)</code>, but it would be surprising if that were an inconsistent error</p>



<a name="214899301"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899301" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899301">(Oct 28 2020 at 21:21)</a>:</h4>
<p>there's much I don't understand, but what I do know is that the custom build command for rustc_llvm failed, I went through the <a href="http://build.rs">build.rs</a> but didn't see anything obvious, and given that the only error keyword among cargo's output involved RustWrapper.cpp I assumed that it originated there</p>



<a name="214899542"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899542" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899542">(Oct 28 2020 at 21:23)</a>:</h4>
<p>do you have any custom llvm config options?</p>



<a name="214899595"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899595" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899595">(Oct 28 2020 at 21:24)</a>:</h4>
<p>llvm-assertions or anything like that?</p>



<a name="214899669"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899669" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899669">(Oct 28 2020 at 21:24)</a>:</h4>
<p>yes, that one is true</p>



<a name="214899694"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899694" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899694">(Oct 28 2020 at 21:25)</a>:</h4>
<p>am also using sccache for llvm</p>



<a name="214899718"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899718" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899718">(Oct 28 2020 at 21:25)</a>:</h4>
<p>ok, I already started my own build with assertions enabled</p>



<a name="214899728"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899728" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899728">(Oct 28 2020 at 21:25)</a>:</h4>
<p>gcc-10.2 on my part</p>



<a name="214899733"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214899733" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214899733">(Oct 28 2020 at 21:25)</a>:</h4>
<p>which I wiped a few times just in case</p>



<a name="214901607"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214901607" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214901607">(Oct 28 2020 at 21:45)</a>:</h4>
<p>my build still passed</p>



<a name="214908860"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214908860" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214908860">(Oct 28 2020 at 23:10)</a>:</h4>
<p>I was able to replicate</p>



<a name="214908921"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214908921" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214908921">(Oct 28 2020 at 23:10)</a>:</h4>
<div class="codehilite"><pre><span></span><code>running: &quot;cmake&quot; &quot;--build&quot; &quot;.&quot; &quot;--target&quot; &quot;install&quot; &quot;--config&quot; &quot;Release&quot; &quot;--&quot; &quot;-j&quot; &quot;8&quot;
[1464/1822] Linking CXX executable bin/llvm-config
FAILED: bin/llvm-config
: &amp;&amp; /usr/bin/c++  -ffunction-sections -fdata-sections -fPIC -m64 -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -DNDEBUG  -Wl,-allow-shlib-undefined    -Wl,-rpath-link,/home/joshua/rustc2/build/x86_64-unknown-linux-gnu/llvm/build/./lib  -Wl,-O3 -Wl,--gc-sections tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o  -o bin/llvm-config  -Wl,-rpath,&quot;\$ORIGIN/../lib&quot; -lLLVM -lpthread &amp;&amp; :
/usr/bin/ld: tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o: in function `ComputeLibsForComponents(std::vector&lt;llvm::StringRef, std::allocator&lt;llvm::StringRef&gt; &gt; const&amp;, bool, bool, std::function&lt;std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt; (llvm::StringRef const&amp;)&gt; const*, std::vector&lt;std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;, std::allocator&lt;std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt; &gt; &gt;*, std::__cxx11::basic_string&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt; const&amp;)&#39;:
llvm-config.cpp:(.text._ZL24ComputeLibsForComponentsRKSt6vectorIN4llvm9StringRefESaIS1_EEbbPKSt8functionIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKS1_EEPS_ISC_SaISC_EERKSC_+0x291): undefined reference to `llvm::deallocate_buffer(void*, unsigned long, unsigned long)&#39;
/usr/bin/ld: tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o: in function `main&#39;:
llvm-config.cpp:(.text.main+0xa7): undefined reference to `llvm::SmallVectorBase&lt;unsigned long&gt;::grow_pod(void*, unsigned long, unsigned long)&#39;
/usr/bin/ld: tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o: in function `std::pair&lt;llvm::StringMapIterator&lt;AvailableComponent*&gt;, bool&gt; llvm::StringMap&lt;AvailableComponent*, llvm::MallocAllocator&gt;::try_emplace&lt;&gt;(llvm::StringRef)&#39;:
llvm-config.cpp:(.text._ZN4llvm9StringMapIP18AvailableComponentNS_15MallocAllocatorEE11try_emplaceIJEEESt4pairINS_17StringMapIteratorIS2_EEbENS_9StringRefEDpOT_[_ZN4llvm9StringMapIP18AvailableComponentNS_15MallocAllocatorEE11try_emplaceIJEEESt4pairINS_17StringMapIteratorIS2_EEbENS_9StringRefEDpOT_]+0x66): undefined reference to `llvm::allocate_buffer(unsigned long, unsigned long)&#39;
clang: error: linker command failed with exit code 1 (use -v to see invocation)
[1471/1822] Building CXX object lib/Passe...akeFiles/LLVMPasses.dir/PassBuilder.cpp.o
ninja: build stopped: subcommand failed.
thread &#39;main&#39; panicked at &#39;
command did not execute successfully, got: exit code: 1

build script failed, must exit now&#39;, /home/joshua/.local/lib/cargo/registry/src/github.com-1ecc6299db9ec823/cmake-0.1.44/src/lib.rs:885:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
    finished in 591.502 seconds
failed to run: /home/joshua/rustc2/build/bootstrap/debug/bootstrap build
Build completed unsuccessfully in 0:09:52
</code></pre></div>



<a name="214908945"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214908945" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214908945">(Oct 28 2020 at 23:10)</a>:</h4>
<div class="codehilite"><pre><span></span><code>$ cat config.toml
# Includes one of the default files in src/bootstrap/defaults
profile = &quot;compiler&quot;
changelog-seen = 2

[build]
doc-stage = 1

[llvm]
download-ci-llvm = false

[rust]
debug = true
</code></pre></div>



<a name="214908966"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214908966" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214908966">(Oct 28 2020 at 23:11)</a>:</h4>
<div class="codehilite"><pre><span></span><code>cmake version 3.13.4
GNU ld (GNU Binutils for Debian) 2.31.1
clang version 8.0.1-3~bpo10+1 (tags/RELEASE_801/final)
</code></pre></div>



<a name="214909003"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214909003" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214909003">(Oct 28 2020 at 23:11)</a>:</h4>
<p>hmm those look like different errors than <span class="user-mention silent" data-user-id="209053">Iñaki Garay</span> was getting</p>



<a name="214910408"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214910408" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214910408">(Oct 28 2020 at 23:30)</a>:</h4>
<p>this one passed for me <br>
<a href="https://github.com/rust-lang/rust/commit/bd145a30489e0dd529889627eb350c9cb5990f71#diff-7cdb6543de7f569620c298122578d643fe4ee829c4e2aa313b129e8932f07929">https://github.com/rust-lang/rust/commit/bd145a30489e0dd529889627eb350c9cb5990f71#diff-7cdb6543de7f569620c298122578d643fe4ee829c4e2aa313b129e8932f07929</a></p>
<p>now re-running on master</p>



<a name="214910461"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214910461" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214910461">(Oct 28 2020 at 23:31)</a>:</h4>
<p>I really should upgrade my cpu</p>



<a name="214915124"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214915124" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214915124">(Oct 29 2020 at 00:48)</a>:</h4>
<div class="codehilite"><pre><span></span><code>gcc (GCC) 9.3.0
</code></pre></div>


<div class="codehilite"><pre><span></span><code>GNU ld (GNU Binutils) 2.34
</code></pre></div>


<div class="codehilite"><pre><span></span><code>cmake version 3.18.2
</code></pre></div>


<div class="codehilite"><pre><span></span><code>changelog-seen = 2

[llvm]
release-debuginfo = true
assertions = true
ccache = &quot;sccache&quot;

[build]
docs = true
compiler-docs = true
submodules = true

[install]

[rust]
debug = true
debug-assertions = true
debug-assertions-std = true
debug-logging = true
debuginfo-level = 1
incremental = true

[target.x86_64-unknown-linux-gnu]
musl-libdir = musl-root/lib

[dist]
</code></pre></div>


<div class="codehilite"><pre><span></span><code>error: failed to run custom build command for `rustc_llvm v0.0.0 (/home/igaray/rust/rust/compiler/rustc_llvm)`

Caused by:
  process didn&#39;t exit successfully: `/home/igaray/rust/rust/build/x86_64-unknown-linux-gnu/stage0-rustc/release/build/rustc_llvm-cfd055f09d335432/build-script-build` (exit code: 1)
  --- stdout
  cargo:rerun-if-env-changed=RUST_CHECK
  cargo:rerun-if-env-changed=REAL_LIBRARY_PATH_VAR
  cargo:rerun-if-env-changed=REAL_LIBRARY_PATH
  cargo:rerun-if-env-changed=LLVM_CONFIG
  cargo:rerun-if-changed=/home/igaray/rust/rust/build/x86_64-unknown-linux-gnu/llvm/build/bin/llvm-config
  cargo:rustc-cfg=llvm_component=&quot;aarch64&quot;
  cargo:rustc-cfg=llvm_component=&quot;arm&quot;
  cargo:rustc-cfg=llvm_component=&quot;asmparser&quot;
  cargo:rustc-cfg=llvm_component=&quot;avr&quot;
  cargo:rustc-cfg=llvm_component=&quot;bitreader&quot;
  cargo:rustc-cfg=llvm_component=&quot;bitwriter&quot;
  cargo:rustc-cfg=llvm_component=&quot;coverage&quot;
  cargo:rustc-cfg=llvm_component=&quot;hexagon&quot;
  cargo:rustc-cfg=llvm_component=&quot;instrumentation&quot;
  cargo:rustc-cfg=llvm_component=&quot;ipo&quot;
  cargo:rustc-cfg=llvm_component=&quot;linker&quot;
  cargo:rustc-cfg=llvm_component=&quot;lto&quot;
  cargo:rustc-cfg=llvm_component=&quot;mips&quot;
  cargo:rustc-cfg=llvm_component=&quot;msp430&quot;
  cargo:rustc-cfg=llvm_component=&quot;nvptx&quot;
  cargo:rustc-cfg=llvm_component=&quot;powerpc&quot;
  cargo:rustc-cfg=llvm_component=&quot;riscv&quot;
  cargo:rustc-cfg=llvm_component=&quot;sparc&quot;
  cargo:rustc-cfg=llvm_component=&quot;systemz&quot;
  cargo:rustc-cfg=llvm_component=&quot;webassembly&quot;
  cargo:rustc-cfg=llvm_component=&quot;x86&quot;
  cargo:rustc-cfg=llvm_has_msp430_asm_parser
  cargo:rerun-if-env-changed=LLVM_RUSTLLVM
  cargo:rerun-if-env-changed=LLVM_NDEBUG
  cargo:rerun-if-changed=llvm-wrapper/PassWrapper.cpp
  cargo:rerun-if-changed=llvm-wrapper/RustWrapper.cpp
  cargo:rerun-if-changed=llvm-wrapper/.editorconfig
  cargo:rerun-if-changed=llvm-wrapper/Linker.cpp
  cargo:rerun-if-changed=llvm-wrapper/LLVMWrapper.h
  cargo:rerun-if-changed=llvm-wrapper/CoverageMappingWrapper.cpp
  cargo:rerun-if-changed=llvm-wrapper/README
  cargo:rerun-if-changed=llvm-wrapper/ArchiveWrapper.cpp
  TARGET = Some(&quot;x86_64-unknown-linux-gnu&quot;)
  OPT_LEVEL = Some(&quot;3&quot;)
  HOST = Some(&quot;x86_64-unknown-linux-gnu&quot;)
  CXX_x86_64-unknown-linux-gnu = Some(&quot;sccache c++&quot;)
  CXXFLAGS_x86_64-unknown-linux-gnu = Some(&quot;-ffunction-sections -fdata-sections -fPIC -m64&quot;)
  CRATE_CC_NO_DEFAULTS = None
  DEBUG = Some(&quot;true&quot;)
  CARGO_CFG_TARGET_FEATURE = Some(&quot;fxsr,sse,sse2&quot;)
  running: &quot;sccache&quot; &quot;c++&quot; &quot;-O3&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-g&quot; &quot;-fno-omit-frame-pointer&quot; &quot;-m64&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-m64&quot; &quot;-I/home/igaray/rust/rust/src/llvm-project/llvm/include&quot; &quot;-I/home
/igaray/rust/rust/build/x86_64-unknown-linux-gnu/llvm/build/include&quot; &quot;-std=c++14&quot; &quot;-fno-exceptions&quot; &quot;-fno-rtti&quot; &quot;-D_GNU_SOURCE&quot; &quot;-D_DEBUG&quot; &quot;-D__STDC_CONSTANT_MACROS&quot; &quot;-D__STDC_FORMAT_MACROS&quot; &quot;-D__STDC_LIMIT_MACROS&quot; &quot;-DLLVM_COMPONENT_AARCH6
4&quot; &quot;-DLLVM_COMPONENT_ARM&quot; &quot;-DLLVM_COMPONENT_ASMPARSER&quot; &quot;-DLLVM_COMPONENT_AVR&quot; &quot;-DLLVM_COMPONENT_BITREADER&quot; &quot;-DLLVM_COMPONENT_BITWRITER&quot; &quot;-DLLVM_COMPONENT_COVERAGE&quot; &quot;-DLLVM_COMPONENT_HEXAGON&quot; &quot;-DLLVM_COMPONENT_INSTRUMENTATION&quot; &quot;-DLLVM_COMPO
NENT_IPO&quot; &quot;-DLLVM_COMPONENT_LINKER&quot; &quot;-DLLVM_COMPONENT_LTO&quot; &quot;-DLLVM_COMPONENT_MIPS&quot; &quot;-DLLVM_COMPONENT_MSP430&quot; &quot;-DLLVM_COMPONENT_NVPTX&quot; &quot;-DLLVM_COMPONENT_POWERPC&quot; &quot;-DLLVM_COMPONENT_RISCV&quot; &quot;-DLLVM_COMPONENT_SPARC&quot; &quot;-DLLVM_COMPONENT_SYSTEMZ&quot; &quot;
-DLLVM_COMPONENT_WEBASSEMBLY&quot; &quot;-DLLVM_COMPONENT_X86&quot; &quot;-DLLVM_RUSTLLVM&quot; &quot;-o&quot; &quot;/home/igaray/rust/rust/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/build/rustc_llvm-f693d55505b398f0/out/llvm-wrapper/PassWrapper
.o&quot; &quot;-c&quot; &quot;llvm-wrapper/PassWrapper.cpp&quot;
  exit code: 0
  running: &quot;sccache&quot; &quot;c++&quot; &quot;-O3&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-g&quot; &quot;-fno-omit-frame-pointer&quot; &quot;-m64&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-m64&quot; &quot;-I/home/igaray/rust/rust/src/llvm-project/llvm/include&quot; &quot;-I/home
/igaray/rust/rust/build/x86_64-unknown-linux-gnu/llvm/build/include&quot; &quot;-std=c++14&quot; &quot;-fno-exceptions&quot; &quot;-fno-rtti&quot; &quot;-D_GNU_SOURCE&quot; &quot;-D_DEBUG&quot; &quot;-D__STDC_CONSTANT_MACROS&quot; &quot;-D__STDC_FORMAT_MACROS&quot; &quot;-D__STDC_LIMIT_MACROS&quot; &quot;-DLLVM_COMPONENT_AARCH6
4&quot; &quot;-DLLVM_COMPONENT_ARM&quot; &quot;-DLLVM_COMPONENT_ASMPARSER&quot; &quot;-DLLVM_COMPONENT_AVR&quot; &quot;-DLLVM_COMPONENT_BITREADER&quot; &quot;-DLLVM_COMPONENT_BITWRITER&quot; &quot;-DLLVM_COMPONENT_COVERAGE&quot; &quot;-DLLVM_COMPONENT_HEXAGON&quot; &quot;-DLLVM_COMPONENT_INSTRUMENTATION&quot; &quot;-DLLVM_COMPO
NENT_IPO&quot; &quot;-DLLVM_COMPONENT_LINKER&quot; &quot;-DLLVM_COMPONENT_LTO&quot; &quot;-DLLVM_COMPONENT_MIPS&quot; &quot;-DLLVM_COMPONENT_MSP430&quot; &quot;-DLLVM_COMPONENT_NVPTX&quot; &quot;-DLLVM_COMPONENT_POWERPC&quot; &quot;-DLLVM_COMPONENT_RISCV&quot; &quot;-DLLVM_COMPONENT_SPARC&quot; &quot;-DLLVM_COMPONENT_SYSTEMZ&quot; &quot;
-DLLVM_COMPONENT_WEBASSEMBLY&quot; &quot;-DLLVM_COMPONENT_X86&quot; &quot;-DLLVM_RUSTLLVM&quot; &quot;-o&quot; &quot;/home/igaray/rust/rust/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/build/rustc_llvm-f693d55505b398f0/out/llvm-wrapper/RustWrapper
.o&quot; &quot;-c&quot; &quot;llvm-wrapper/RustWrapper.cpp&quot;
  cargo:warning=In file included from /usr/include/c++/9.3/bits/move.h:55,
  cargo:warning=                 from /usr/include/c++/9.3/bits/nested_exception.h:40,
  cargo:warning=                 from /usr/include/c++/9.3/exception:144,
  cargo:warning=                 from /usr/include/c++/9.3/new:40,
  cargo:warning=                 from /home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Compiler.h:21,
  cargo:warning=                 from /home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/ErrorHandling.h:17,
  cargo:warning=                 from /home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/ADT/Hashing.h:48,
  cargo:warning=                 from /home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/ADT/ArrayRef.h:12,
  cargo:warning=                 from llvm-wrapper/LLVMWrapper.h:4,
  cargo:warning=                 from llvm-wrapper/RustWrapper.cpp:1:
  cargo:warning=/usr/include/c++/9.3/type_traits: In instantiation of &#39;struct std::is_base_of&lt;llvm::MDNode, LLVMOpaqueMetadata&gt;&#39;:
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:105:36:   recursively required by substitution of &#39;template&lt;class To, class From&gt; struct llvm::isa_impl&lt;To, From, typename std::enable_if&lt;std::is_b
ase_of&lt;_Base, _Derived&gt;::value, void&gt;::type&gt; [with To = llvm::MDNode; From = LLVMOpaqueMetadata]&#39;
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:105:36:   required from &#39;static bool llvm::isa_impl_cl&lt;To, const From*&gt;::doit(const From*) [with To = llvm::MDNode; From = LLVMOpaqueMetadata]&#39;
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:131:40:   required from &#39;static bool llvm::isa_impl_wrap&lt;To, FromTy, FromTy&gt;::doit(const FromTy&amp;) [with To = llvm::MDNode; FromTy = const LLVMOpaqu
eMetadata*]&#39;
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:122:60:   required from &#39;static bool llvm::isa_impl_wrap&lt;To, From, SimpleFrom&gt;::doit(const From&amp;) [with To = llvm::MDNode; From = LLVMOpaqueMetadat
a* const; SimpleFrom = const LLVMOpaqueMetadata*]&#39;
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:143:74:   required from &#39;bool llvm::isa(const Y&amp;) [with X = llvm::MDNode; Y = LLVMOpaqueMetadata*]&#39;
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm/Support/Casting.h:269:3:   required from &#39;typename llvm::cast_retty&lt;X, Y*&gt;::ret_type llvm::cast(Y*) [with X = llvm::MDNode; Y = LLVMOpaqueMetadata; typename llvm::ca
st_retty&lt;X, Y*&gt;::ret_type = llvm::MDNode*]&#39;
  cargo:warning=llvm-wrapper/RustWrapper.cpp:939:31:   required from here
  cargo:warning=/usr/include/c++/9.3/type_traits:1301:12: error: invalid use of incomplete type &#39;struct LLVMOpaqueMetadata&#39;
  cargo:warning= 1301 |     struct is_base_of
  cargo:warning=      |            ^~~~~~~~~~
  cargo:warning=In file included from /home/igaray/rust/rust/src/llvm-project/llvm/include/llvm-c/BitReader.h:23,
  cargo:warning=                 from llvm-wrapper/LLVMWrapper.h:1,
  cargo:warning=                 from llvm-wrapper/RustWrapper.cpp:1:
  cargo:warning=/home/igaray/rust/rust/src/llvm-project/llvm/include/llvm-c/Types.h:89:16: note: forward declaration of &#39;struct LLVMOpaqueMetadata&#39;
  cargo:warning=   89 | typedef struct LLVMOpaqueMetadata *LLVMMetadataRef;
  cargo:warning=      |                ^~~~~~~~~~~~~~~~~~
  exit code: 1
</code></pre></div>



<a name="214915401"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214915401" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214915401">(Oct 29 2020 at 00:53)</a>:</h4>
<p>when I run the <code>c++</code> command by itself, without sccache, it emits the same output capture by cargo</p>



<a name="214915521"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214915521" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214915521">(Oct 29 2020 at 00:55)</a>:</h4>
<div class="codehilite"><pre><span></span><code>  --- stderr

  error occurred: Command &quot;sccache&quot; &quot;c++&quot; &quot;-O3&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-g&quot; &quot;-fno-omit-frame-pointer&quot; &quot;-m64&quot; &quot;-ffunction-sections&quot; &quot;-fdata-sections&quot; &quot;-fPIC&quot; &quot;-m64&quot; &quot;-I/home/igaray/rust/rust/src/llvm-project/llvm/in
clude&quot; &quot;-I/home/igaray/rust/rust/build/x86_64-unknown-linux-gnu/llvm/build/include&quot; &quot;-std=c++14&quot; &quot;-fno-exceptions&quot; &quot;-fno-rtti&quot; &quot;-D_GNU_SOURCE&quot; &quot;-D_DEBUG&quot; &quot;-D__STDC_CONSTANT_MACROS&quot; &quot;-D__STDC_FORMAT_MACROS&quot; &quot;-D__STDC_LIMIT_MACROS&quot; &quot;-DLLVM_C
OMPONENT_AARCH64&quot; &quot;-DLLVM_COMPONENT_ARM&quot; &quot;-DLLVM_COMPONENT_ASMPARSER&quot; &quot;-DLLVM_COMPONENT_AVR&quot; &quot;-DLLVM_COMPONENT_BITREADER&quot; &quot;-DLLVM_COMPONENT_BITWRITER&quot; &quot;-DLLVM_COMPONENT_COVERAGE&quot; &quot;-DLLVM_COMPONENT_HEXAGON&quot; &quot;-DLLVM_COMPONENT_INSTRUMENTATION
&quot; &quot;-DLLVM_COMPONENT_IPO&quot; &quot;-DLLVM_COMPONENT_LINKER&quot; &quot;-DLLVM_COMPONENT_LTO&quot; &quot;-DLLVM_COMPONENT_MIPS&quot; &quot;-DLLVM_COMPONENT_MSP430&quot; &quot;-DLLVM_COMPONENT_NVPTX&quot; &quot;-DLLVM_COMPONENT_POWERPC&quot; &quot;-DLLVM_COMPONENT_RISCV&quot; &quot;-DLLVM_COMPONENT_SPARC&quot; &quot;-DLLVM_COMPO
NENT_SYSTEMZ&quot; &quot;-DLLVM_COMPONENT_WEBASSEMBLY&quot; &quot;-DLLVM_COMPONENT_X86&quot; &quot;-DLLVM_RUSTLLVM&quot; &quot;-o&quot; &quot;/home/igaray/rust/rust/rust/build/x86_64-unknown-linux-gnu/stage0-rustc/x86_64-unknown-linux-gnu/release/build/rustc_llvm-f693d55505b398f0/out/llvm-wrapper/RustWrapper.o&quot; &quot;-c&quot; &quot;llvm-wrapper/RustWrapper.cpp&quot; with args &quot;c++&quot; did not execute successfully (status code exit code: 1).
</code></pre></div>


<p>^ last bit was truncated by zulip</p>



<a name="214916379"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214916379" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214916379">(Oct 29 2020 at 01:09)</a>:</h4>
<p>let me know if there is somewhere more useful I can share this information</p>



<a name="214928621"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214928621" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214928621">(Oct 29 2020 at 05:39)</a>:</h4>
<p>Can you try changing <code>DL</code> to <code>unwrap(DL)</code> on that line 939?</p>



<a name="214948341"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214948341" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214948341">(Oct 29 2020 at 10:19)</a>:</h4>
<p>good call!<br>
in effect, this makes the build complete:</p>
<div class="codehilite" data-code-language="Diff"><pre><span></span><code><span class="gh">diff --git a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp</span>
<span class="gh">index 3beb328339e..c689ac9427a 100644</span>
<span class="gd">--- a/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp</span>
<span class="gi">+++ b/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp</span>
<span class="gu">@@ -936,7 +936,7 @@ extern "C" LLVMValueRef LLVMRustDIBuilderInsertDeclareAtEnd(</span>
   return wrap(Builder-&gt;insertDeclare(
       unwrap(V), unwrap&lt;DILocalVariable&gt;(VarInfo),
       Builder-&gt;createExpression(llvm::ArrayRef&lt;int64_t&gt;(AddrOps, AddrOpsCount)),
<span class="gd">-      DebugLoc(cast&lt;MDNode&gt;(DL)),</span>
<span class="gi">+      DebugLoc(cast&lt;MDNode&gt;(unwrap(DL))),</span>
       unwrap(InsertAtEnd)));
 }
</code></pre></div>



<a name="214992538"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214992538" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214992538">(Oct 29 2020 at 16:29)</a>:</h4>
<p>thanks for confirming -- I'll put that in a PR</p>



<a name="214993150"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214993150" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Iñaki Garay <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214993150">(Oct 29 2020 at 16:33)</a>:</h4>
<p>thank you for your attention, it gets a lot less lonely and frustrating when you have someone to talk to</p>



<a name="214995663"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/halp%3A%20rustc_llvm%20build%20fail/near/214995663" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/halp.3A.20rustc_llvm.20build.20fail.html#214995663">(Oct 29 2020 at 16:52)</a>:</h4>
<p><a href="https://github.com/rust-lang/rust/pull/78531">https://github.com/rust-lang/rust/pull/78531</a></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>